#!/bin/sh

# Build zipfiles for gnome-vfs on Win32. Separate runtime and
# developer ones.  After running make install, run this.

ZIP=/tmp/gnome-vfs-@VERSION@.zip
DEVZIP=/tmp/gnome-vfs-dev-@VERSION@.zip

cd @prefix@
rm $ZIP

current_minus_age=`expr @LIBGNOMEVFS_CURRENT@ - @LIBGNOMEVFS_AGE@`

zip $ZIP -@ <<EOF
bin/libgnomevfs-2-$current_minus_age.dll
etc/gconf/schemas/system_http_proxy.schemas
etc/gnome-vfs-2.0/modules/default-modules.conf
EOF

zip $ZIP lib/gnome-vfs-2.0/modules/*.dll

if [ -f share/locale/de/LC_MESSAGES/gnome-vfs-2.0.mo ]; then
  zip $ZIP share/locale/*/LC_MESSAGES/gnome-vfs-2.0.mo
else
  zip $ZIP lib/locale/*/LC_MESSAGES/gnome-vfs-2.0.mo
fi

rm $DEVZIP
zip -r $DEVZIP -@ <<EOF
bin/gnomevfs-cat.exe
bin/gnomevfs-copy.exe
bin/gnomevfs-info.exe
bin/gnomevfs-ls.exe
bin/gnomevfs-mkdir.exe
bin/gnomevfs-monitor.exe
bin/gnomevfs-mv.exe
lib/libgnomevfs-2.dll.a
lib/pkgconfig/gnome-vfs-2.0.pc
lib/pkgconfig/gnome-vfs-module-2.0.pc
include/gnome-vfs-2.0
include/gnome-vfs-module-2.0
share/gtk-doc/html/gnome-vfs-2.0
EOF
